export default class SettingScene extends Phaser.Scene {
    create() {
        // 半透明背景
        this.add.rectangle(540, 960, 800, 1200, 0x000000, 0.7)
            .setInteractive();

        // 设置选项
        const options = [
            { text: '音乐音量', y: 600 },
            { text: '音效音量', y: 800 },
            { text: '返回', y: 1000 }
        ];

        options.forEach(opt => {
            this.add.text(540, opt.y, opt.text, { 
                fontFamily: 'pixel_font',
                fontSize: '48px'
            }).setInteractive()
              .on('pointerdown', () => {
                  if (opt.text === '返回') this.scene.resume('MainMenu');
              });
        });
    }
}